home *** CD-ROM | disk | FTP | other *** search
- //
- // Large Hall.
- //
- // This is really a monophonic to stereo reverberator.
- // The stereo inputs are summed to a monophonic signal
- // and sent through the reverberator. Stereo outputs are
- // obtained by summing different sets of taps within the
- // reverberator. This creates spatial impression by
- // decorrelating the stereo outputs, although this method
- // is not as good as using different reverberators for
- // each channel. Note that by adjusting the tap offsets,
- // one can create particular localization cues for the
- // early and later echoes.
- //
- // The reverberator itself is based on cascaded and nested
- // allpass filters. These create a sufficiently dense echo
- // buildup and do not suffer from a fluttery decay like
- // the Schroeder style reverberator based on comb filters.
- //
- // The reverberation time is set by adjusting the feedback
- // gain in the comb_lpf instruction. The brightness of the
- // reverb is set by adjusting the lowpass cutoff in the same
- // instruction. The amount of direct sound is set by adjusting
- // the direct taps in the output FIR intructions. If clipping
- // occurs, the inputs should be further attenuated.
- //
- // Bill Gardner, October, 1992
- //
- #include "macros.rvb"
-
- //
- // MIDI ctl 1 -> effects mix
- // MIDI ctl 2 -> reverberation time
- // MIDI ctl 3 -> diffusion
- // MIDI ctl 4 -> brightness
- //
- #define mix init(0.5,ctl(1))
- #define decay range(init(40/127,ctl(2)),0.4,0.8)
- #define diffuse 2 * init(0.5,ctl(3))
- #define bright init(25/127,0.01+ctl(4))
-
- addr("x");
- // make monophonic mix at location 0
- fir(0,
- Lin, 0.5,
- Rin, 0.5);
- // lowpass filter
- lpf(2, bright * 8000);
-
- // two series allpasses
- allpass(3, 334, 0.3 * diffuse);
- allpass(335, 846, 0.3 * diffuse);
-
- // allpass within allpass
- allpass(1768, 5623, 0.5 * diffuse);
- allpass(1769, 4501, 0.25 * diffuse);
- move(7120, y:0);
-
- // two serial allpass within single allpass
- addr("y");
- allpass(1, 5293, 0.5 * diffuse);
- allpass(2, 3335, 0.25 * diffuse);
- allpass(3336, 4659, 0.25 * diffuse);
-
- // feedback through lowpass filter
- comb_lpf(x:1, y:5300, decay, 8000 * bright);
-
- // left channel output taps, first tap is direct sound
- fir(Lout,
- Lin, 1 - mix,
- x:1000, 0.6 * mix,
- x:7000, 0.3 * mix,
- y:5300, 0.3 * mix);
-
- // right channel output taps, first tap is direct sound
- fir(Rout,
- Rin, 1 - mix,
- x:1000, 0.6 * mix,
- x:7035, 0.3 * mix,
- y:5295, 0.3 * mix);
-